package com.iqiyi.pps.epg.core.model.carousel;

/**
 * Created by karkarrotxu on 2016/1/18.
 */

import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

import javax.persistence.*;
import java.sql.Timestamp;

@Entity
@Table(name = "autocarousel_episode_rule")
@Cache(usage = CacheConcurrencyStrategy.NONE)
public class AutoCarouselEpisodeRule implements IIndexSort{
    public static final int STATUS_IDLE = 0;
    public static final int STATUS_RUN = 1;

    public static final int STATUS_DELETE = -1;
    public static final int STATUS_ILLEGAL = -2;

    public static final int STATUS_PROGRAM_RUN = 2;
    public static final int STATUS_PROGRAM_IDLE = 3;

    public static final int TYPE_ALBUM = 1;
    public static final int TYPE_PROGRAM = 2;
    private long id;
    private long fatherId;
    private long qipuId;
    private String showName;
    private String channelTag;
    private int bossStatus;
    private int publishStatus;
    private String pageUrl;
    private int totalNum;
    private int actualNum;
    private long execIndex;
    private int currentExec;
    private int lastCreatedNo;
    private int status;
    private Timestamp executeTime;
    private Timestamp createdTime;
    private Timestamp updateTime;
    private String opUser;
    private long lastSortTime;
    private int type = TYPE_ALBUM;

    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }


    @Column(name = "father_id")
    public long getFatherId() {
        return fatherId;
    }

    public void setFatherId(long fatherId) {
        this.fatherId = fatherId;
    }

    @Column(name = "qipu_id")
    public long getQipuId() {
        return qipuId;
    }

    public void setQipuId(long qipuId) {
        this.qipuId = qipuId;
    }

    @Column(name = "show_name")
    public String getShowName() {
        return showName;
    }

    public void setShowName(String showName) {
        this.showName = showName;
    }

    @Column(name = "channel_tag")
    public String getChannelTag() {
        return channelTag;
    }

    public void setChannelTag(String channelTag) {
        this.channelTag = channelTag;
    }

    @Column(name = "boss_status")
    public int getBossStatus() {
        return bossStatus;
    }

    public void setBossStatus(int bossStatus) {
        this.bossStatus = bossStatus;
    }

    @Column(name = "publish_status")
    public int getPublishStatus() {
        return publishStatus;
    }

    public void setPublishStatus(int publishStatus) {
        this.publishStatus = publishStatus;
    }

    @Column(name = "page_url")
    public String getPageUrl() {
        return pageUrl;
    }

    public void setPageUrl(String pageUrl) {
        this.pageUrl = pageUrl;
    }

    @Column(name = "total_num")
    public int getTotalNum() {
        return totalNum;
    }

    public void setTotalNum(int totalNum) {
        this.totalNum = totalNum;
    }

    @Column(name = "actual_num")
    public int getActualNum() {
        return actualNum;
    }

    public void setActualNum(int actualNum) {
        this.actualNum = actualNum;
    }

    @Column(name = "exec_index")
    public long getExecIndex() {
        return execIndex;
    }

    public void setExecIndex(long execIndex) {
        this.execIndex = execIndex;
    }



    @Column(name = "current_exec")
    public int getCurrentExec() {
        return currentExec;
    }

    public void setCurrentExec(int currentExec) {
        this.currentExec = currentExec;
    }

    @Column(name = "last_created_no")
    public int getLastCreatedNo() {
        return lastCreatedNo;
    }

    public void setLastCreatedNo(int lastCreatedNo) {
        this.lastCreatedNo = lastCreatedNo;
    }

    @Column(name = "status" , updatable=false)
    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    @Column(name = "execute_time")
    public Timestamp getExecuteTime() {
        return executeTime;
    }

    public void setExecuteTime(Timestamp executeTime) {
        this.executeTime = executeTime;
    }

    @Column(name = "created_time", updatable = false)
    public Timestamp getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(Timestamp createdTime) {
        this.createdTime = createdTime;
    }

    @Column(name = "update_time", updatable = false)
    public Timestamp getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Timestamp updateTime) {
        this.updateTime = updateTime;
    }

    @Column(name = "op_user")
    public String getOpUser() {
        return opUser;
    }

    public void setOpUser(String opUser) {
        this.opUser = opUser;
    }

    @Column(name = "last_sort_time")
    public long getLastSortTime() {
        return lastSortTime;
    }

    public void setLastSortTime(long lastSortTime) {
        this.lastSortTime = lastSortTime;
    }

    @Column(name = "type")
    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }
}